cmake_minimum_required(VERSION 3.8)
project(openvino_test)

# 针对 Debug 模式的编译选项
set(CMAKE_BUILD_TYPE "Debug")
set(CMAKE_CXX_FLAGS_DEBUG "-g -O0")
set(CMAKE_C_FLAGS_DEBUG "-g -O0")


# Default to C++17
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# find dependencies
find_package(OpenCV REQUIRED)
find_package(PCL REQUIRED)

include_directories(
    include
    "/usr/include/openvino/"
    "/usr/include/openvino/runtime/"
    ${OPENCV_INCLUDE_DIRS}
    ${PCL_INCLUDE_DIRS}
)

link_directories("/usr/lib/openvino-2024.6.0/")
link_directories(${PCL_LIBRARY_DIRS})
add_definitions(${PCL_DEFINITIONS})

add_executable(test_openvino 
  src/test_openvino.cpp
  src/yoloInterface.cpp
)
target_link_libraries(test_openvino ${OpenCV_LIBS} openvino)

add_executable(calcu_edge 
  src/calcu_edge.cpp
  src/yoloInterface.cpp
)
target_link_libraries(calcu_edge ${OpenCV_LIBS} ${PCL_LIBRARIES} openvino)
